package com.sl.leetcode;

import org.junit.Test;

import java.lang.reflect.Method;

/**
 * Created by lisulong on 2019/9/18.
 */
public class TemplateClass {
    @Test
    public  void indexTest() throws Exception {
        Method[] methods = this.getClass().getDeclaredMethods();
        for (Method method:methods){
            if (method.getName().equals(Thread.currentThread().getStackTrace()[1].getMethodName())) continue;
            System.out.println(method.invoke(this.getClass().newInstance(),new int[]{1,2,3}));
        }
    }
}
